﻿<%@ Page Title="" Language="C#" MasterPageFile="~/Views/Shared/Site.Master" Inherits="System.Web.Mvc.ViewPage<Kkc.Model.Announcement>" %>

<asp:Content ID="Content1" ContentPlaceHolderID="TitleContent" runat="server">
	<%= Html.Encode(Model.Title) %>
</asp:Content>

<asp:Content ID="Content2" ContentPlaceHolderID="MainContent" runat="server">

    <h1><%= Html.Encode(Model.Title) %></h1>
    <p><i><%= Html.Encode(Model.Summary) %></i></p>
    <p><%= Model.Body %></p>
    <% if (!string.IsNullOrEmpty(Model.Link)) { %>
    <p>&rsaquo;&nbsp;<a href="<%= Model.Link %>" title="Gå til ekstern side..." target="_blank">Besøk ekstern side.</a></p>
    <% } %>
    
</asp:Content>

<asp:Content ID="Content3" ContentPlaceHolderID="LeftSideContent" runat="server">
    <ul>
        <li class="first"><%=Html.ActionLink("Tilbake til nyheter", "Index") %></li>
        <% if (Page.User.IsInRole("Contributor")) { %>
        <li><%= Html.ActionLink("Opprett ny artikkel", "Create") %></li>
        <li><%=Html.ActionLink("Rediger", "Edit", new { id=Model.Id }) %></li>
        <% } %>
    </ul>
</asp:Content>

